package com.test.stream;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.stream.Stream;

/**
 * @author RenGaoshuai
 * @date 2023/11/27 9:50
 * @description
 */
public class CreateStream {
    public static void main(String[] args) {
        List<String> list = new ArrayList<>();

        //普通流
        Stream<String> stream = list.stream();

        //并行流
        Stream<String> stringStream = list.parallelStream();


        String[] array = new String[20];
        Stream<String> arrayStream = Arrays.stream(array);

        Stream<String> ofStream = Stream.of("ade", "sdede", "ded");

    }
}
